package io.renren.modules.lucky.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import io.renren.common.service.impl.CrudServiceImpl;
import io.renren.modules.lucky.dao.LuckyRecordDetailsDao;
import io.renren.modules.lucky.dto.LuckyRecordDetailsDTO;
import io.renren.modules.lucky.entity.LuckyRecordDetailsEntity;
import io.renren.modules.lucky.service.LuckyRecordDetailsService;
import cn.hutool.core.util.StrUtil;
import org.springframework.stereotype.Service;

import java.util.Map;

/**
 * 招财猫埋点记录表
 *
 * @author Liang Pei 
 * @since 1.0.0 2025-01-07
 */
@Service
public class LuckyRecordDetailsServiceImpl extends CrudServiceImpl<LuckyRecordDetailsDao, LuckyRecordDetailsEntity, LuckyRecordDetailsDTO> implements LuckyRecordDetailsService {

    @Override
    public QueryWrapper<LuckyRecordDetailsEntity> getWrapper(Map<String, Object> params){
        String id = (String)params.get("id");

        QueryWrapper<LuckyRecordDetailsEntity> wrapper = new QueryWrapper<>();
        wrapper.eq(StrUtil.isNotBlank(id), "id", id);

        return wrapper;
    }


}